package cn.acewill.yxd.yunxundian.utils;

import org.xutils.DbManager;
import org.xutils.db.table.TableEntity;
import org.xutils.x;

/**
 * Created by AAA on 2017/4/5.
 */

public class JsonDbUtils {
    private DbManager db;

    DbManager.DaoConfig daoConfig = new DbManager.DaoConfig()
            .setDbName("xutils3_db") //设置数据库名
            .setDbVersion(1) //设置数据库版本,每次启动应用时将会检查该版本号,
            //发现数据库版本低于这里设置的值将进行数据库升级并触发DbUpgradeListener
            .setAllowTransaction(true)//设置是否开启事务,默认为false关闭事务
            .setTableCreateListener(new DbManager.TableCreateListener() {
                @Override
                public void onTableCreated(DbManager db, TableEntity<?> table) {


                }
            })
            .setDbUpgradeListener(new DbManager.DbUpgradeListener() {
                @Override
                public void onUpgrade(DbManager db, int oldVersion, int newVersion) {

                }
            });

}